package com.test.ml.mybatis.mapper;

import java.util.List;

import com.test.ml.mybatis.entity.TestEntity;
import org.apache.ibatis.annotations.*;

import com.test.ml.mybatis.entity.UserBak;

public interface UserMapper {
	@SelectProvider(type= SqlProvader.class,method = "getByCode")
//	@Select(value="select * FROM sys_user WHERE user_code LIKE concat('%',#{code},'%')")
	@Results({@Result(column="org_id",property="orgId"),
		@Result(column="sex_id",property="sexId"),
		@Result(column="remark",property="remark"),
		@Result(column="user_code",property="userCode"),
		@Result(column="user_password",property="userPasswrod")})
	public List<UserBak> getByCode(String code);

	@SelectProvider(type=SqlProvader.class,method = "getTestCode")
	@Results({@Result(column="ID",property="id"),
			@Result(column="NAME",property="name"),
			@Result(column="AGE",property="age"),
			@Result(column="SCOER",property="score")})
	public List<TestEntity> getByName(String name);
}
